package com.saihai.jiankang.ufSsrwLog.service.impl;

import java.util.List;
import com.saihai.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.saihai.jiankang.ufSsrwLog.mapper.UfSsrwLogMapper;
import com.saihai.jiankang.ufSsrwLog.domain.UfSsrwLog;
import com.saihai.jiankang.ufSsrwLog.service.IUfSsrwLogService;

/**
 * 体检记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-07-18
 */
@Service
public class UfSsrwLogServiceImpl implements IUfSsrwLogService 
{
    @Autowired
    private UfSsrwLogMapper ufSsrwLogMapper;

    /**
     * 查询体检记录
     * 
     * @param id 体检记录主键
     * @return 体检记录
     */
    @Override
    public UfSsrwLog selectUfSsrwLogById(Long id)
    {
        return ufSsrwLogMapper.selectUfSsrwLogById(id);
    }

    /**
     * 查询体检记录
     *
     * @return 体检记录
     */
    @Override
    public UfSsrwLog selectUfSsrwLogNum(UfSsrwLog UfSsrwLog)
    {
        return ufSsrwLogMapper.selectUfSsrwLogNum(UfSsrwLog);
    }


    /**
     * 查询体检记录列表
     * 
     * @param ufSsrwLog 体检记录
     * @return 体检记录
     */
    @Override
    public List<UfSsrwLog> selectUfSsrwLogList(UfSsrwLog ufSsrwLog)
    {
        return ufSsrwLogMapper.selectUfSsrwLogList(ufSsrwLog);
    }

    /**
     * 新增体检记录
     * 
     * @param ufSsrwLog 体检记录
     * @return 结果
     */
    @Override
    public int insertUfSsrwLog(UfSsrwLog ufSsrwLog)
    {
        ufSsrwLog.setCreateTime(DateUtils.getNowDate());
        return ufSsrwLogMapper.insertUfSsrwLog(ufSsrwLog);
    }

    /**
     * 修改体检记录
     * 
     * @param ufSsrwLog 体检记录
     * @return 结果
     */
    @Override
    public int updateUfSsrwLog(UfSsrwLog ufSsrwLog)
    {
        ufSsrwLog.setUpdateTime(DateUtils.getNowDate());
        return ufSsrwLogMapper.updateUfSsrwLog(ufSsrwLog);
    }

    /**
     * 批量删除体检记录
     * 
     * @param ids 需要删除的体检记录主键
     * @return 结果
     */
    @Override
    public int deleteUfSsrwLogByIds(Long[] ids)
    {
        return ufSsrwLogMapper.deleteUfSsrwLogByIds(ids);
    }

    /**
     * 删除体检记录信息
     * 
     * @param id 体检记录主键
     * @return 结果
     */
    @Override
    public int deleteUfSsrwLogById(Long id)
    {
        return ufSsrwLogMapper.deleteUfSsrwLogById(id);
    }
}
